<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>添加游戏</title>
    <link rel="stylesheet" href="${pageContext.request.contextPath }/static/css/bootstrap.min.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath }/static/css/bootstrap-datetimepicker.css">
    <!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
    <script src="${pageContext.request.contextPath }/static/jquery-1.10.2.min.js"></script>
    <script src="${pageContext.request.contextPath }/static/bootstrap.min.js"></script>
    <script src="${pageContext.request.contextPath }/static/bootstrap-datetimepicker.min.js" charset="UTF-8"></script>
</head>
<body>
<div class="row">
    <div class="col-lg-4">

        <form action="${pageContext.request.contextPath}/role/insert" method="post" class="form-horizontal">
            <div class="form-group">
                <label class="col-sm-2 control-label"></label>
                <div class="col-sm-4">
                    <h5 style="color: #bd1f1d">${insertInfo}</h5>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-2 control-label">游戏：</label>
                <div class="col-sm-4">
                    <select class="form-control" name="gameId">
                        <option value="">——请选择——</option>
                        <c:forEach items="${gameList}" var="item">
                            <option value="${item.id}">${item.gameName}</option>
                        </c:forEach>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-2 control-label">角色名：</label>
                <div class="col-sm-4">
                    <input type="text" class="form-control" name="roleName">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-2 control-label">角色等级：</label>
                <div class="col-sm-4">
                    <input type="text" class="form-control" name="roleGrade">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-2 control-label">注册日期：</label>
                <div class="col-sm-4">
                    <input type="text" class="form-control" id="recordDate" name="recordDate">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-2 control-label">状态：</label>
                <div class="col-sm-4">
                    <label class="control-label"><input type="radio" name="status" value="1">正常</label>
                    <label class="control-label"><input type="radio" name="status" value="2">禁用</label>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-offset-2 col-sm-2">
                    <button type="submit" class="btn btn-success">提交</button>
                </div>
            </div>
        </form>
    </div>
</div>
<script>
    $(function () {
        $('#recordDate').datetimepicker({
            format: 'yyyy-mm-dd',
            autoclose: true,
            minView: 2
        });
    })
    }
</script>
</body>
</html>
